package club.pinea.scheduled;

import club.pinea.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

@Component
public class UserTimeOutSchedule {

    @Autowired
    private UserService userService;

    @Scheduled(cron = "0 5/5 * * * ? ")
    public void scheduled() {
        //定时执行更新用户信息操作
        userService.updateTimeOutUser();
        userService.updateOutBoundsGameTime();
    }

}
